In [6]:
import trimesh

def load_mesh_scene(filename, show_edges=False):
    mesh = trimesh.load(filename)
    color = [128, 176, 255, 255]
    mesh.visual.face_colors = color
    geometries = [mesh]
    if show_edges:
        edges = mesh.face_adjacency_edges
        path = trimesh.path.Path3D(**trimesh.path.exchange.misc.edges_to_path(edges, mesh.vertices.copy()))
        geometries.append(path)
    scene = trimesh.Scene(geometries)
    return scene, mesh
In [21]:
scene, mesh = load_mesh_scene("mesh5.stl")
In [22]:
mesh.vertices
Out[22]:
TrackedArray([[1969.        , 2137.        ,  156.26358032],
              [1969.        , 2136.        ,  134.95491028],
              [1968.        , 2137.        ,  123.11676025],
              ...,
              [3788.        , 3109.        ,  243.8658905 ],
              [3799.        , 3074.        ,  246.23352051],
              [3785.        , 3113.        ,  243.8658905 ]])
In [23]:
scene.show()
Out[23]: